/**
 * 
 */
package com.ordoict.smallsettlement.business.generic.dao;

import java.util.List;

import org.springframework.dao.DataAccessException;

/**
 * <pre>
 * vCloud.biz.backOffice.web.dao
 * GenericDAO.java
 * </pre>
 *
 * Desc: 최상위 DAO 인터페이스
 *       기본적인 CRUD 를 정의함.
 *       모든 DAO 인터페이스는
 *       GenericDAO<T> 인터페이스를 상속을 권장함.
 * @Company  : OrdoICT.,Inc
 * @author   : Choi Jin Wook / choijinwook84@ordoict.com
 * @Date     : 2011. 8. 25. 오전 11:58:29
 * @Version  :
 *
 * @param <T>
 */
public interface GenericDAO<T> {
    
    /**
     * Desc: 조회
     * @Mehtod Name : get
     * @param entity
     * @return
     * @throws DataAccessException
     */
    T get(T entity) throws DataAccessException;
    
    /**
     * Desc: 리스트
     * @Mehtod Name : getList
     * @param entity
     * @return
     * @throws DataAccessException
     */
    List<T> getList(T entity) throws DataAccessException;
    
    /**
     * Desc: 카운트
     * @Mehtod Name : count
     * @param entity
     * @return
     * @throws DataAccessException
     */
    Integer count(T entity) throws DataAccessException;

    /**
     * Desc: 등록
     * @Mehtod Name : add
     * @param entity
     * @return
     * @throws DataAccessException
     */
    T add(T entity) throws DataAccessException;
    
    /**
     * Desc: 수정
     * @Mehtod Name : update
     * @param entity
     * @return
     * @throws DataAccessException
     */
    T update(T entity) throws DataAccessException;
    
    /**
     * Desc: 삭제
     * @Mehtod Name : delete
     * @param entity
     * @throws DataAccessException
     */
    int delete(T entity) throws DataAccessException;
    
    /**
     * Desc: Procedure, Package 실행
     * @Mehtod Name : get
     * @param entity
     * @return
     * @throws DataAccessException
     */
    T psm(T entity) throws DataAccessException;
    
}